package main

import "fmt"

func main() {

	person := map[int]string{
		1: "Tom",
		2: "Aaron",
		3: "John",
	}
	fmt.Println("len=%d map=%v\n", len(person), person)
	fmt.Printf("")

	//循环
	for k, V := range person {
		fmt.Println("person[%d]: %s\n", k, V)
	}

	fmt.Println("")

	for i := 1; i <= len(person); i++ {
		fmt.Printf("person[%d]: %s\n", i, person[i])
	}

	fmt.Println("")

	//使用空白符
	for _, name := range person {
		fmt.Println("name :", name)
	}

}
